package cli

import (
	"blockchaingo/block"
	"blockchaingo/wallet"
	"fmt"
	"log"
)

func (cli *CLI) createBlockchain(address string) {

	if !wallet.ValidateAddress(address) {
		log.Panic("ERROR: Address is not valid")
	}

	bc := block.CreateBlockchain(address)
	defer block.Close(bc)
	
	utxo := block.UTXOSet{bc}
	utxo.Reindex()
	fmt.Println("createBlockchain Done!")
	

}
